package edu.nepu.flink.api.sql;

import org.apache.flink.streaming.api.environment.StreamExecutionEnvironment;
import org.apache.flink.table.api.bridge.java.StreamTableEnvironment;

/**
 * @Date 2024/3/5 21:10
 * @Created by chenshuaijun
 */
public class CreateTableEnv {

    public static void main(String[] args) throws Exception {

        // 首先介绍的是创建表的环境
        StreamExecutionEnvironment env = StreamExecutionEnvironment.getExecutionEnvironment();

        StreamTableEnvironment tableEnv = StreamTableEnvironment.create(env);

        /**
         * execute要不要调用主要看的是要看我们是否使用了Stream的API,如果使用了就需要调用，如果没使用就不需要调用
         */
        env.execute();

    }
}
